.class Les/fe0$a;
.super Ljava/lang/Object;
.source "OBEXAuthentication.java"


# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Les/fe0;
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x8
    name = "a"
.end annotation


# instance fields
.field private a:Ljava/lang/String;

.field private b:Z

.field private c:Z

.field d:[B


# direct methods
.method constructor <init>([B)V
    .locals 0
    .annotation system Ldalvik/annotation/Throws;
        value = {
            Ljava/io/IOException;
        }
    .end annotation

    .line 1
    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    .line 2
    invoke-virtual {p0, p1}, Les/fe0$a;->a([B)V

    return-void
.end method


# virtual methods
.method public a()Ljava/lang/String;
    .locals 1

    .line 21
    iget-object v0, p0, Les/fe0$a;->a:Ljava/lang/String;

    return-object v0
.end method

.method a([B)V
    .locals 9
    .annotation system Ldalvik/annotation/Throws;
        value = {
            Ljava/io/IOException;
        }
    .end annotation

    const-string v0, "authChallenge"

    .line 1
    invoke-static {v0, p1}, Les/be0;->a(Ljava/lang/String;[B)V

    const/4 v0, 0x0

    const/4 v1, 0x0

    .line 2
    :goto_0
    array-length v2, p1

    if-ge v1, v2, :cond_9

    .line 3
    aget-byte v2, p1, v1

    const/16 v3, 0xff

    and-int/2addr v2, v3

    add-int/lit8 v4, v1, 0x1

    .line 4
    aget-byte v4, p1, v4

    and-int/2addr v4, v3

    add-int/lit8 v1, v1, 0x2

    if-eqz v2, :cond_7

    const/4 v5, 0x1

    if-eq v2, v5, :cond_4

    const/4 v5, 0x2

    if-eq v2, v5, :cond_0

    .line 5
    new-instance v3, Ljava/lang/StringBuilder;

    invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V

    const-string v5, "invalid authChallenge tag "

    invoke-virtual {v3, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v3, v2}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v2

    invoke-static {v2}, Les/be0;->b(Ljava/lang/String;)V

    goto/16 :goto_3

    .line 6
    :cond_0
    aget-byte v2, p1, v1

    and-int/2addr v2, v3

    add-int/lit8 v5, v4, -0x1

    .line 7
    new-array v6, v5, [B

    add-int/lit8 v7, v1, 0x1

    .line 8
    invoke-static {p1, v7, v6, v0, v5}, Ljava/lang/System;->arraycopy(Ljava/lang/Object;ILjava/lang/Object;II)V

    if-ne v2, v3, :cond_1

    .line 9
    invoke-static {v6}, Les/xe0;->a([B)Ljava/lang/String;

    move-result-object v2

    iput-object v2, p0, Les/fe0$a;->a:Ljava/lang/String;

    goto/16 :goto_3

    :cond_1
    const-string v3, "ASCII"

    if-nez v2, :cond_2

    .line 10
    new-instance v2, Ljava/lang/String;

    invoke-direct {v2, v6, v3}, Ljava/lang/String;-><init>([BLjava/lang/String;)V

    iput-object v2, p0, Les/fe0$a;->a:Ljava/lang/String;

    goto :goto_3

    :cond_2
    const/16 v7, 0x9

    if-gt v2, v7, :cond_3

    .line 11
    new-instance v3, Ljava/lang/String;

    new-instance v5, Ljava/lang/StringBuilder;

    invoke-direct {v5}, Ljava/lang/StringBuilder;-><init>()V

    const-string v7, "ISO-8859-"

    invoke-virtual {v5, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v5, v2}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    invoke-virtual {v5}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v2

    invoke-direct {v3, v6, v2}, Ljava/lang/String;-><init>([BLjava/lang/String;)V

    iput-object v3, p0, Les/fe0$a;->a:Ljava/lang/String;

    goto :goto_3

    .line 12
    :cond_3
    new-instance v7, Ljava/lang/StringBuilder;

    invoke-direct {v7}, Ljava/lang/StringBuilder;-><init>()V

    const-string v8, "Unsupported charset code "

    invoke-virtual {v7, v8}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v7, v2}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    const-string v2, " in Challenge"

    invoke-virtual {v7, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v7}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v2

    invoke-static {v2}, Les/be0;->b(Ljava/lang/String;)V

    .line 13
    new-instance v2, Ljava/lang/String;

    invoke-direct {v2, v6, v0, v5, v3}, Ljava/lang/String;-><init>([BIILjava/lang/String;)V

    iput-object v2, p0, Les/fe0$a;->a:Ljava/lang/String;

    goto :goto_3

    .line 14
    :cond_4
    aget-byte v2, p1, v1

    int-to-long v6, v2

    const-string v3, "authChallenge options"

    .line 15
    invoke-static {v3, v6, v7}, Les/be0;->a(Ljava/lang/String;J)V

    and-int/lit8 v3, v2, 0x1

    if-eqz v3, :cond_5

    const/4 v3, 0x1

    goto :goto_1

    :cond_5
    const/4 v3, 0x0

    .line 16
    :goto_1
    iput-boolean v3, p0, Les/fe0$a;->b:Z

    and-int/lit8 v2, v2, 0x2

    if-nez v2, :cond_6

    goto :goto_2

    :cond_6
    const/4 v5, 0x0

    .line 17
    :goto_2
    iput-boolean v5, p0, Les/fe0$a;->c:Z

    goto :goto_3

    :cond_7
    const/16 v2, 0x10

    if-ne v4, v2, :cond_8

    new-array v3, v2, [B

    .line 18
    iput-object v3, p0, Les/fe0$a;->d:[B

    .line 19
    invoke-static {p1, v1, v3, v0, v2}, Ljava/lang/System;->arraycopy(Ljava/lang/Object;ILjava/lang/Object;II)V

    :goto_3
    add-int/2addr v1, v4

    goto/16 :goto_0

    .line 20
    :cond_8
    new-instance p1, Ljava/io/IOException;

    const-string v0, "OBEX Digest Challenge error in tag Nonce"

    invoke-direct {p1, v0}, Ljava/io/IOException;-><init>(Ljava/lang/String;)V

    throw p1

    :cond_9
    return-void
.end method

.method public b()Z
    .locals 1

    .line 1
    iget-boolean v0, p0, Les/fe0$a;->c:Z

    return v0
.end method

.method public c()Z
    .locals 1

    .line 1
    iget-boolean v0, p0, Les/fe0$a;->b:Z

    return v0
.end method
